package com.blog.controller;

/**
 * @Description: 苹果类
 * @Author: 刘会俊
 * @Date: 2019-01-23 13:49
 */
public class Apple extends Fruit {

    public static void main(String[] args) {
        System.out.println(test(true));
    }


    public static int test(boolean isException){
        int i = 1;
        try {
            if(isException) throw new Exception();
            return i;
        } catch (Exception e) {
            i = 2;
            return i;
        } finally {
            i = 3;
            return i;
        }
    }

}
